<?php

class SendMailForm extends CFormModel {

    public $email;
    public $subject;
    public $body;

    /**
     * Declares the validation rules.
     */
    public function rules() {
        return array(
            // name, email, subject and body are required
            array('email, subject, body', 'required'),
            // email has to be a valid email address
            array('email', 'email'),
            array('body', 'length', 'min' => 10),
        );
    }

}